<?php /*a:2:{s:82:"D:\phpstudy_pro\WWW\kaoshi.com\web/../application/plus_exam/view\question\add.html";i:1533518098;s:76:"D:\phpstudy_pro\WWW\kaoshi.com\web/../application/plus_exam/view\layout.html";i:1533518098;}*/ ?>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title><?php echo $app_name; ?></title>
<meta name="renderer" content="webkit">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<link rel="stylesheet" type="text/css" href="__PUBLIC__/base.css" />
<link rel="stylesheet" type="text/css" href="__PUBLIC__/iconfont.css" />
<link rel="stylesheet" type="text/css" href="__PUBLIC__/admin/style.css" />
<script type="text/javascript" src="__PUBLIC__/js/do.js"></script>
<script type="text/javascript" src="__PUBLIC__/js/config.js"></script>
</head>
<body>
<div class="main">
<form id="form" action="<?php echo url('plus_exam/question/add'); ?>">
<input type="hidden" name="type" value="<?php echo $type; ?>">
<table class="formtable">
<tr>
<th>题库类型:</th>
<td>
    <select class="select" name="category_id" datatype="*">
        <option value=""></option>
        <?php if(is_array($category_list) || $category_list instanceof \think\Collection || $category_list instanceof \think\Paginator): $i = 0; $__LIST__ = $category_list;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$rs): $mod = ($i % 2 );++$i;?>
            <option value="<?php echo $rs['id']; ?>"><?php echo $rs['name']; ?></option>
        <?php endforeach; endif; else: echo "" ;endif; ?>
    </select>
</td>
</tr>
<tr>
<th>题目内容:</th>
<td>
    <textarea datatype="*" class="textarea w400 h80" name="content"></textarea>
</td>
</tr>
<?php if($type == 1): ?>
<tr>
    <th>题目选项:<!--单选--></th>
    <td>
        <table class="w500">
            <thead>
            </thead>
            <tbody>
            <?php if(is_array($add_option_list) || $add_option_list instanceof \think\Collection || $add_option_list instanceof \think\Paginator): $i = 0; $__LIST__ = $add_option_list;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$rs): $mod = ($i % 2 );++$i;?>
            <tr>
                <td class="fn-r">
                    <input type="radio" value="<?php echo $key; ?>" name="answer" />
                    <?php echo $key; ?>. <input  class="input w400" type="text"  name="option_list[<?php echo $key; ?>]" value="" />
                </td>
            </tr>
            <?php endforeach; endif; else: echo "" ;endif; ?>
            </tbody>
        </table>
    </td>
</tr>
<?php elseif($type == 2): ?>
<tr>
    <th>题目选项:<!--多选--></th>
    <td>
        <table class="w500">
            <thead>
            </thead>
            <tbody>
            <?php if(is_array($add_option_list) || $add_option_list instanceof \think\Collection || $add_option_list instanceof \think\Paginator): $i = 0; $__LIST__ = $add_option_list;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$rs): $mod = ($i % 2 );++$i;?>
                <tr>
                    <td class="fn-r">
                        <input  type="checkbox" value="<?php echo $key; ?>" name="answer[<?php echo $key; ?>]">
                        <?php echo $key; ?>. <input  class="input w400" type="text"  name="option_list[<?php echo $key; ?>]" value="" />
                    </td>
                </tr>
            <?php endforeach; endif; else: echo "" ;endif; ?>
            </tbody>
        </table>
    </td>
</tr>
<?php elseif($type == 3): ?>
<tr>
    <th>题目选项:<!--判断--></th>
    <td>
        <table class="w500">
            <tbody>
            <?php if(is_array($add_option_list) || $add_option_list instanceof \think\Collection || $add_option_list instanceof \think\Paginator): $i = 0; $__LIST__ = $add_option_list;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$rs): $mod = ($i % 2 );++$i;?>
                <tr>
                    <td class="fn-tal">
                        <input  type="radio" value="<?php echo $key; ?>" name="answer" /> <?php echo $rs; ?>
                    </td>
                </tr>
            <?php endforeach; endif; else: echo "" ;endif; ?>
            </tbody>
        </table>
    </td>
</tr>
<?php endif; ?>
<tr>
    <th></th>
    <td>
        <input type="submit" value="<?php echo app('lang')->get('lang_ui_save'); ?>" class="button button-blue submit" />
        <input type="reset" value="<?php echo app('lang')->get('lang_ui_reset'); ?>" class="button button-blank"/>
    </td>
</tr>
</table>
</div>
<script type="text/javascript">
Do('base','layer','form',function(){
$('#form').isForm();
});
</script>
</div>
<script type="text/javascript">
<?php if(isset($pathMaps)): ?>
    parent.pathMaps(<?php echo $pathMaps; ?>);
<?php endif; if(isset($editMenu)): ?>
    parent.editMenu(<?php echo $editMenu; ?>);
<?php endif; ?>
</script>
</body>
</html>